Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix PIL version check #7716

Merged
merged 2 commits into from
Jul 3, 2023
Merged

fix PIL version check #7716

merged 2 commits into from
Jul 3, 2023

Conversation

pmeier
Copy link
Collaborator

@pmeier pmeier commented Jul 3, 2023

Example failure: https://hud.pytorch.org/pr/pytorch/vision/7715#14733928493

The string comparison worked before, since the major version was < 10:

assert "9.6.1" > "7"

With the new release of Pillow==10.0.0, this no longer works:

assert not ("10.0.0" > "7")

This PR changes the check to a numeric one to avoid this issue.

I've grep'ed through the codebase and there is no other occurrence of PIL.__version__ or Image.__version__.

@pytorch-bot
Copy link

pytorch-bot bot commented Jul 3, 2023

🔗 Helpful Links

🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/vision/7716

Note: Links to docs will display an error until the docs builds have been completed.

❌ 33 New Failures

As of commit 7ca37d8:

NEW FAILURES - The following jobs have failed:

This comment was automatically generated by Dr. CI and updates every 15 minutes.

Copy link
Member

@NicolasHug NicolasHug left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM but PIL 7 was released in 2020 and there's no chance our CI still relies on it. We should probably be fixing this test or delete it

@pmeier
Copy link
Collaborator Author

pmeier commented Jul 3, 2023

Since it has been skipped since quite some time now and no one complained, I'm in favor of removal.

@NicolasHug
Copy link
Member

OK to remove as well, as long as we have our decent PIL <=> tensor equivalence tests.

@pmeier
Copy link
Collaborator Author

pmeier commented Jul 3, 2023

The test itself is over 6 years old and was added in #275. It was deactivated over three years ago in #1735.

@pmeier pmeier merged commit c3e9256 into pytorch:main Jul 3, 2023
@pmeier pmeier deleted the pil-version-check branch July 3, 2023 11:33
@github-actions
Copy link

github-actions bot commented Jul 3, 2023

Hey @pmeier!

You merged this PR, but no labels were added. The list of valid labels is available at https://github.com/pytorch/vision/blob/main/.github/process_commit.py

facebook-github-bot pushed a commit that referenced this pull request Aug 25, 2023
Reviewed By: matteobettini

Differential Revision: D48642310

fbshipit-source-id: 572982b35611216a46049a2d5309fd00cd2ab901
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants